import itertools

def inHoanVi(a):
    print list(itertools.permutations(a))

x =[1,2,3]
inHoanVi(x)